Welcome Guest, you are in: Login
CTS Futures
Home
Pricing
Market Data
FAQ
Videos

T4 Desktop
User Guide
Scripting Guide
Release Notes

Mobile and Web
T4 Mobile for Android
T4 Mobile for iOS
T4 Mobile for Browser
T4 WebTrader

Admins
T4 Admin Guide
MiFID II/MiFIR

Developers
API 4.7 Guide
FIX API


Search Engine

Here you can search through the pages of this Namespace, their attachments and the files uploaded to the system.
Note: the results will only display the items you have permissions to read.



Filter by Category


This search, performed through 6.78 MB (320 documents, 6085 words), completed in 0.3 seconds and yielded 30 results.

Scripting Overview — 3.3%

Code Structure Scripting code consists of one or more statements that are executed by the script interpreter. Individual statements are separated by semicolons. White spaces (spaces, tabs, carriage returns, etc.) have no effect on how scripts are interpreted. Scripts are case-insensitive (e.g. sma is the same as SMA ). Statements can do the following: Perform a calculation. Assign a value or calculation to a variable name. Accept user input into a variable. Plot values on a chart in various different formats. Configure the chart. [...]

Walkthrough #1 - A Basic Example — 0.8%

This walkthrough is intended to demonstrate the very basics of scripting. A chart script is composed of one or more script "statements". A statement can be either a mathematical function that produces a value, an assignment of a function to a variable to use later in the script, or a command instructing the scripting engine what or how to plot a value on chart. Before we get started, you should have a chart [...]

T4 Chart Scripting Site Map — 0.6%

T4 [...]

Scripting Function Reference — 0.6%

[...] Index of the current bar being computed. This runs from 0 to COUNT - 1. COUNT Number of bars on the chart. BARPERCENT Percentage completion of the current bar. E.g. 15 minutes into a 1 hour bar would give 0.25 NUMERATOR The numerator of the market. DENOMINATOR The denominator of the market. TICKVALUE The tick value of the market. NIL Special "non-value" field. MARKETID The text market id. MARKETDESCRIPTION The text description of the market. Operators Arithmetic Operators Operator Description + Add - Subtract / Divide * Multiply [...]

INPUT Function — 0.6%

The input function allows for user configuration of script parameters to customize a script on a chart. For example, a script that used a moving average would use the INPUT function to get the number of periods to use for the moving average. That would allow the same script to be used on multiple charts with different values for the number of periods. Numeric Values INPUT( label >, number >, min value >, max value >) Function Parameters Parameter Description label > The label [...]

MOV Function — 0.5%

[...] average of the value over the specified number of periods using the specified moving average type. Function Parameters Parameter Description value > The value to compute the moving average of. periods > The number of periods to compute the moving average over. MAType > The type of moving average to compute. MAType can be specified as follows: MAType Parameter Description MAType.SMA Simple moving average. MAType.SMMA Smoothed moving average. MAType.EMA Exponential moving average. MAType.LWMA Linear weighted moving [...]

T4 Chart Scripting — 0.5%

Help on how to create custom chart indicators and studies. The Advanced Data and Charting package is required to create custom studies. Overview Function [...]

Walkthrough #1 - Creating a New Custom Script-Based Study — 0.4%

[...] create new script-based studies to add to your charts. To start, click the Add Study button on the chart to open the Add Study window. The Add Study window will open. Click the New Custom Study button to create a new script-based study. The window will change to following: Here you will select whether you would like to create an overlay or an indicator study. Overlay studies appear on the same chart panel as the price bars and their study values are in prices. Indicator studies appear in their own chart [...]

DISPLAY Function — 0.4%

[...] specified tick value to a text representation of the price. Note: you cannot use the output of this function in any mathematical computation. Function Parameters Parameter Description value > The tick value to convert to display text. Note: You can use the @ shortcut instead of using the full formula name as well: SUMMARY("Close: [...]

ACCUM Function — 0.4%

ACCUM( value > ) Accumulates (sums) a value over all the data points on the chart. Function Parameters Parameter Description value > The value field to compute. Example: x = 1; ACCUM(x); Example Data Date Open High Low Close Volume x ACCUM(x) 06/01/2011 75100 76050 74100 75875 106528 1 1 06/02/2011 75750 77000 75450 76650 81891 1 2 06/03/2011 76550 76900 75100 75200 80819 1 3 06/06/2011 75400 75800 73150 73175 82726 1 4 06/07/2011 73200 73775 72925 73675 72927 1 5 06/08/2011 73875 76650 73450 76275 113339 1 6 06/09/2011 [...]

MAX Function — 0.3%

MAX( value >, ... value n > ) Returns the largest of the specified values. Function Parameters Parameter Description value 1 to n > The values to evaluate. Examples: MAX(5, 10, 9, 8) Evaluates to 10 Back to the

MOD Function — 0.3%

MOD( value 1 >, value 2 > ) Returns the remainder of the division of value 1 by value 2. Function Parameters Parameter Description value 1 > The value to divide. value 2 > The value to divide by. Back to the

MIN Function — 0.3%

MIN( value >, ... value n > ) Returns the smallest of the specified values. Function Parameters Parameter Description value 1 to n > The values to evaluate. Examples: MIN(5, 10, 9, 8) Evaluates to 5 Back to the

LOWEST Function — 0.3%

[...] ) Returns the lowest value occurring over the last number of periods from the current data point. Function Parameters Parameter Description value > The value field to inspect (e.g. CLOSE , HIGH , (H+L+C)/3 , etc.) periods > The number of periods to look back. Example: LOWEST(CLOSE, 5) Example Data Date Open High Low Close Volume LOWEST(CLOSE, 5) 06/01/2011 75100 76050 74100 75875 106528 75875 06/02/2011 75750 77000 75450 76650 81891 75875 06/03/2011 76550 76900 75100 75200 80819 75200 06/06/2011 75400 75800 73150 73175 82726 73175 06/07/2011 73200 [...]

LOG10 Function — 0.3%

LOG10( value > ) Computes the base 10 logarithm of the value. Function Parameters Parameter Description value > The value to compute. Back to the

STDDEVP Function — 0.3%

[...] Computes the standard deviation (entire population) of the value over the specified number of periods. Function Parameters Parameter Description value > The value to compute the standard deviation of. periods > The number of periods to compute the standard deviation over. Back to the

STDDEV Function — 0.3%

[...] >, periods > ) Computes the standard deviation of the value over the specified number of periods. Function Parameters Parameter Description value > The value to compute the standard deviation of. periods > The number of periods to compute the standard deviation over. Back to the

SUM Function — 0.3%

SUM( value >, periods > ) Computes the sum of the values over the specified number of periods. Function Parameters Parameter Description value > The value field to compute (e.g. CLOSE , HIGH , (H+L+C)/3 , etc.) periods > The number of periods to sum over. Example: SUM(VOLUME, 5) Example Data Date Open High Low Close Volume SUM(VOLUME, 5) 06/01/2011 75100 76050 74100 75875 106528 06/02/2011 75750 77000 75450 76650 81891 06/03/2011 76550 76900 75100 75200 80819 06/06/2011 75400 75800 73150 73175 82726 06/07/2011 73200 73775 72925 73675 72927 424891 [...]

TAN Function — 0.3%

TAN( value > ) Computes the tangent of the value. Function Parameters Parameter Description value > The value to compute. Back to the

SQRT Function — 0.3%

SQRT( value > ) Computes the square root of the value. Function Parameters Parameter Description value > The value to compute. Back to the

OFFSET Function — 0.3%

OFFSET( value >, periods > ) Gets the value offset by the specified number of periods. Function Parameters Parameter Description value > The value to look up. periods > The number of periods to look back or forward. Note: A negative periods > value retrieves previous values, whereas a positive periods > retrieves forward values (looks ahead). Back to the

POW Function — 0.3%

POW( value >, power > ) Computes the value raised to the specified power. Function Parameters Parameter Description value > The value to raise. power > The power to raise the value. Back to the

SIN Function — 0.3%

SIN( value > ) Computes the sine of the value. Function Parameters Parameter Description value > The value to compute. Back to the

ROC Function — 0.3%

[...] periods > ) Computes the rate of change of the specified value over the specified number of periods. Function Parameters Parameter Description value > The value to compute the rate of change of. periods > The number of periods to look back while computing the rate of change. Back to the

COS Function — 0.3%

COS( value > ) Computes the cosine of the value. Function Parameters Parameter Description value > The value to compute. Back to the

CEILING Function — 0.3%

CEILING( value > ) Computes the nearest larger integer to the value. Function Parameters Parameter Description value > The value to compute. Examples: CEILING(5.8) Evaluates to 6 CEILING(-5.8) Evaluates to -5 Back to the

ATAN Function — 0.3%

ATAN( value > ) Computes the inverse tangent of the value. Function Parameters Parameter Description value > The value to compute. Back to the

Cross Above Function — 0.3%

[...] CROSS_ABOVE( value1 >, value2 > ) Returns 1 when value1 crosses above value2. Returns 0 otherwise. Function Parameters Parameter Description value1 > The first value. value1 > The second value. Example: CROSS_ABOVE(CLOSE, OPEN) Back to the

ABS Function — 0.3%

ABS( value > ) Calculates the absolute value of a number. Function Parameters Parameter Description value > The value to compute (e.g. CLOSE , HIGH , (H+L+C)/3 , etc.) Examples: ABS(5.8) Evaluates to 5.8 ABS(-5.8) Evaluates to 5.8 Back to the

CASH Function — 0.3%

[...] specified tick value to a cash value using the conversion parameters defined for the current market. Function Parameters Parameter Description value > The tick value to convert to cash. Note: You can use the $ shortcut instead of using the full formula name as well: cashval = $tickval; Back to the

Trade how you want, where you want

support@ctsfutures.com (312) 939 0164

2 Pierce Pl, Suite 200, Itasca, IL 60143

© 2009-2023 Cunningham Trading Systems LLC All rights reserved.